 <?php
 require_once('./admin/View/inc_admin.php');
 ?> 
 <div id="content">
    <div class="inner" style="min-height:1200px;">
      <div class="row">
        <div class="col-xs-12">
            <!doctype html>
            <html lang="zh-cn">
            <head>
              <meta charset="UTF-8">  
              <title>留言列表</title>
              <link rel="stylesheet" href="./admin/View/assets/css/bootstrap.min.css">
          </head>
          <body> 

            <center><h3>留言列表</h3></center>
            <div class="container-fluid col-md-offset-2 col-md-8">
                <table align="center"  class="table table-striped"> 
                    <tr class="success">                            
                        <th>序号</th>
                        <th>视频名称</th>
                        <th>留言内容</th>
                        <th>留言人</th>
                        <th>发表时间</th>
                        <th>操作</th>
                    </tr>                              
                    <?php 
                    foreach ($data['comments'] as $row)  {
                        echo '<tr>';
                        echo '<td class="active">'.$row['cid'].'</td>';
                        echo '<td>'.$row['videoname'].'</td>';
                        echo '<td>'.$row['comment'].'</td>';
                        echo '<td>'.$row['uname'].'</td>';
                        echo '<td>'.$row['cdate'].'</td>';
                        echo '<td><a href="index.php?c=comment&m=delete3&id='.$row['cid'].'"onClick="return confirm(\'确定要删除吗？\');">删除</a></td>';
                        echo '</tr>';
                    }
                    echo '</table>';
                    $totalrows = count($data['comments']);
                    echo "<table align='center'><tr><td>共有{$totalrows}条留言</td></tr></table>";
                    ?>
                </table>
            </div>
        </div>
    </div>
    <hr />
</div>
<script src="./admin/View/assets/plugins/jquery-2.0.3.min.js"></script>
<script src="./admin/View/assets/plugins/bootstrap/js/bootstrap.min.js"></script>
<script src="./admin/View/assets/plugins/modernizr-2.6.2-respond-1.1.0.min.js"></script>
</body>
</html> 